#include "downloaderbase.h"
#include "downloaderwindow.h"

DownloaderBase base;

DownloaderWindow::DownloaderWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::DownloaderWindow)
{
    ui->setupUi(this);
}

DownloaderWindow::~DownloaderWindow()
{
    delete ui;
}


void DownloaderWindow::on_pushButton_clicked()
{
    base.NotifyDebugger();
}

void DownloaderWindow::on_webView_loadFinished(bool arg1)
{
    this->PlainPage = (ui->webView->page()->currentFrame()->toPlainText());
    // create a Parser instance
    QJson::Parser parser;
    bool ok;
    // json is a QString containing the data to convert
    result = parser.parse (QByteArray().append(PlainPage), &ok);
}
